

public class TestMain {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		/*
		try {
		ByteArrayOutputStream baos = new ByteArrayOutputStream();
	    Document document = new Document(PageSize.A4);
	    PdfWriter writer;
		writer = PdfWriter.getInstance(document, baos);
	    writer.setViewerPreferences(PdfWriter.AllowPrinting  | PdfWriter.PageLayoutSinglePage);
	    BaseFont bf = BaseFont.createFont("C:\\WINDOWS\\FONTS\\ARIALUNI.TTF",BaseFont.IDENTITY_H,BaseFont.NOT_EMBEDDED);
	    Font font = new Font(bf, 12, Font.NORMAL);
	    document.open();
	    Paragraph p = new Paragraph("你好", font); 
	    document.add(p);
	    document.add(new Paragraph("Test2"));
	    Table table = new Table(2, 3);
	    table.addCell(new Phrase("我好", font));
	    table.addCell("C2R1");
	    table.addCell("C1R2");
	    table.addCell("C2R2");
	    Cell c = (Cell) table.getElement(0, 0);
	    c.setVerticalAlignment("Middle");
	    c.setBackgroundColor(new Color(255, 0, 0));
	    c.setHorizontalAlignment("Center");
	    document.add(table);
	    document.close();
	    baos.writeTo(new FileOutputStream("C://test//test.pdf"));  
		} catch (Exception e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		*/
	}

}
